package com.buddyface;

import android.app.NotificationManager;
import android.app.Notification;
import android.app.PendingIntent;
import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.os.IBinder;
import android.util.Log;

public class BFService extends Service {
	
	private int APP_NOTIFICATION_ID = 1;
	private static final String TAG = "arnaud";
	

	@Override
	public void onCreate() {
	    super.onCreate(); 
	    Log.d(TAG, "Creating Service"); 
	    
	    /*
	    // Get the notification manager service.
	    String ns = Context.NOTIFICATION_SERVICE;
	    NotificationManager mNotificationManager = (NotificationManager) getSystemService(ns);
	    
	    int icon = R.drawable.icon;
	    CharSequence tickerText = "Hello";
	    long when = System.currentTimeMillis();

	    Notification notification = new Notification(icon, tickerText, when);
	    
	    Context context = getApplicationContext();
	    CharSequence contentTitle = "My notification";
	    CharSequence contentText = "Hello World!";
	    Intent notificationIntent = new Intent(this, BFService.class);
	    PendingIntent contentIntent = PendingIntent.getActivity(this, 0, notificationIntent, 0);

	    notification.setLatestEventInfo(context, contentTitle, contentText, contentIntent);

	    mNotificationManager.notify(APP_NOTIFICATION_ID, notification);
	    
        // Create myReceiver
        BFBroadcastReceiver myReceiver = new BFBroadcastReceiver();
        
        // Create myFilter associated with myReceiver
        IntentFilter myFilter = new IntentFilter("android.provider.Telephony.SMS_RECEIVED");
        
        // Register myReceiver
        this.registerReceiver(myReceiver, myFilter);
        */
	} 
	
	 
	@Override
	public IBinder onBind(Intent intent) {
		// TODO Auto-generated method stub
		return null;
	}

}
